<?php

include '../functions.php'; 

try{
	$db = new PDO("mysql:host=localhost;dbname=school;charset=utf8","root","");

	// $sql = "insert into34523 stu (name,age,sex) values('小马',18,'男')";


	// $res = $db->exec($sql);

	// if(!$res){
	// 	var_dump($db->errorInfo());
	// }

	// var_dump($res);
	$sql = "select * from stu";

	$sql = "show tables";

	$sql = "desc stu";

	$res = $db->query($sql);

	var_dump($res->fetchAll(PDO::FETCH_ASSOC));

}catch(PDOException  $e ){
	echo "Error: ".$e;
}



















 ?>